<?php
namespace app\user\event\subscribes\user;

use think\Event;
use app\user\logic\user\SystemNotify;

class Notify
{
    public function subscribe(Event $event)
    {

    	// 讲师认证审核结果发送通知消息
        $event->listen('TeacherExamine', function ($param) {
            $param['title'] 		= '讲师认证审核通知';
	        app(SystemNotify::class)::create($param);
        });

    	// 机构认证审核结果发送通知消息
        $event->listen('SchoolExamine', function ($param) {
            $param['title'] 		= '机构认证审核通知';
	        app(SystemNotify::class)::create($param);
        });

    	// 课时审核结果发送通知消息
        $event->listen('SectionExamine', function ($param) {
            $param['title'] 		= '课时审核通知';
            $param['is_link'] 		= 0;	// 前期均跳转至我的授课列表页
	        app(SystemNotify::class)::create($param);
        });

    }
}
